<template>
    <p>选项式 生命周期
        count:{{count}}
        <button @click="onAdd">add</button>
    </p>
</template>

<script >
    export default {
        name: 'lifeCircle',
        props: ['name'],
        emits: ['check'],
        data () {
            return {
                count: 1
            }
        },
        methods: {
            onAdd() {
                this.count ++
            }
        },
        computed: {

        },

        beforeCreate(vm) {
            console.log('beforeCreate')
        },
        created(vm) {
            console.log('created')
        },
        beforeMount(vm) {
            console.log('beforeMount')
        },
        mounted(vm) {
            console.log('mounted')
        },
        beforeUpdate(vm) {
            console.log(vm)
            console.log('beforeUpdate')
        },
        updated(vm) {
            console.log('updated')
        },
        beforeUnmounted() {

        },
         unmounted() {

        }

    }
</script>

<style>

</style>